Skip to content

feat: improve CLI UX consistency#36

Merged
lusu007 merged 19 commits intomainfrom
cli-ux-consistency
May 4, 2026
Merged

feat: improve CLI UX consistency#36
lusu007 merged 19 commits intomainfrom
cli-ux-consistency

Conversation

@lusu007
Copy link
Copy Markdown
Contributor

@lusu007 lusu007 commented May 4, 2026

Summary

  • Add shared CLI status rendering helpers and apply them across doctor, auth/init, workspace, push, preview, DevSpace, bundle, and logs commands.
  • Improve command help/examples and make grounds push the primary deploy command while preserving push list and push retry.
  • Clarify the global --output flag scope and add regression coverage for UX-sensitive output paths.

Impact

  • CLI output is more consistent with the doctor and version --check UX.
  • Invalid push command shapes like grounds push push and grounds push list unexpected now fail before Gradle/auth/API work.
  • The old arrow/check/warning copy patterns were removed from user-facing command output.

Test Plan

  • go test ./...
  • go build ./cmd/grounds
  • rg -n "→|✔|⚠|'grounds [^']+'" cmd/grounds internal/render
  • Manual smoke checks for root/help, doctor, logs --help, and invalid push args

@lusu007 lusu007 self-assigned this May 4, 2026
@lusu007 lusu007 changed the title Improve CLI UX consistency feat: improve CLI UX consistency May 4, 2026
@lusu007 lusu007 marked this pull request as ready for review May 4, 2026 20:24
Copilot AI review requested due to automatic review settings May 4, 2026 20:24
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR standardizes human-facing CLI messaging across the Grounds CLI, shifts grounds push to be the primary deploy entrypoint, and refreshes help/example text so common workflows read more consistently.

Changes:

  • Added shared render helpers for status badges, detail lines, and inline command formatting, then applied them across auth, init, workspace, push, preview, bundle, DevSpace, and doctor flows.
  • Made grounds push the direct deploy command while keeping push list and push retry, with stricter argument handling and new regression tests around invalid command shapes.
  • Updated command descriptions/examples and added tests for UX-sensitive output paths.

Reviewed changes

Copilot reviewed 34 out of 34 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
internal/render/status.go Reworked paused-workspace messaging to use shared render helpers.
internal/render/status_test.go Updated paused status assertions for new warning output.
internal/render/message.go Added shared status/detail/command render helpers.
internal/render/message_test.go Added unit coverage for new render helpers.
cmd/grounds/commands/version.go Refreshed version command summary and examples.
cmd/grounds/commands/root.go Updated root CLI descriptions and --output help text.
cmd/grounds/commands/root_test.go Added regression test for updated --output usage text.
cmd/grounds/commands/push/retry.go Switched retry confirmation output to shared status rendering.
cmd/grounds/commands/push/push.go Made root push command perform deploys directly and tightened arg handling/messages.
cmd/grounds/commands/push/push_test.go Added coverage for new push command structure, arg validation, and output helpers.
cmd/grounds/commands/push/list.go Added arg validation and shared pagination warning rendering.
cmd/grounds/commands/preview/preview.go Updated preview help text and human-readable output formatting.
cmd/grounds/commands/preview/preview_test.go Added coverage for preview pin summary helper.
cmd/grounds/commands/logs/logs.go Improved logs command help text and examples.
cmd/grounds/commands/logs/logs_test.go Added regression test for logs examples.
cmd/grounds/commands/logout.go Switched logout success output to shared status rendering.
cmd/grounds/commands/logout_test.go Added logout output regression test.
cmd/grounds/commands/login.go Switched login flow messaging to shared status/detail rendering.
cmd/grounds/commands/login_test.go Added coverage for login subject formatting.
cmd/grounds/commands/init.go Updated init success output to shared status/detail format.
cmd/grounds/commands/init_test.go Added assertion for new init output text.
cmd/grounds/commands/doctor.go Reused shared render helpers for doctor results.
cmd/grounds/commands/devspace/generate.go Switched DevSpace generate success output to shared status rendering.
cmd/grounds/commands/devspace/generate_test.go Added helper coverage and renamed one test case for clarity.
cmd/grounds/commands/devspace/devspace.go Added examples to the DevSpace command.
cmd/grounds/commands/cluster/up.go Added examples and updated workspace/bundle result output formatting.
cmd/grounds/commands/cluster/up_test.go Added regression test for bundle result rendering.
cmd/grounds/commands/cluster/status.go Switched missing-workspace message to shared warning rendering.
cmd/grounds/commands/cluster/down.go Switched pause confirmation to shared status rendering.
cmd/grounds/commands/cluster/delete.go Updated delete warnings/results to shared status/detail rendering.
cmd/grounds/commands/cluster/cluster.go Added cluster command examples.
cmd/grounds/commands/bundle/show.go Updated bundle show help text to use inline command formatting.
cmd/grounds/commands/bundle/list.go Updated bundle list empty-state output and help text.
cmd/grounds/commands/bundle/bundle.go Added bundle command examples.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread cmd/grounds/commands/cluster/down.go Outdated
Comment thread cmd/grounds/commands/login.go Outdated
Comment thread cmd/grounds/commands/root.go Outdated
@lusu007 lusu007 force-pushed the cli-ux-consistency branch from b774403 to 13dc41b Compare May 4, 2026 20:52
@lusu007 lusu007 merged commit 45a0855 into main May 4, 2026
9 checks passed
@lusu007 lusu007 deleted the cli-ux-consistency branch May 4, 2026 20:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants